	
// Studerende.h : Declaration of the CStuderende

#ifndef __STUDERENDE_H_
#define __STUDERENDE_H_

#include "resource.h"       // main symbols
#include "StuderendeImpl.h"
#include "EnumAdresse.h"

/////////////////////////////////////////////////////////////////////////////
// CStuderende
class ATL_NO_VTABLE CStuderende : 
	public CComObjectRootEx<CComMultiThreadModel>,
	public CComCoClass<CStuderende, &CLSID_Studerende>,
	public ISupportErrorInfo,
	public IDispatchImpl<IStuderende, &IID_IStuderende, &LIBID_EBASDLLLib>
{
public:
	CStuderende()
	{
		m_pUnkMarshaler = NULL;
		m_studImpl = new CStuderendeImpl;
	}

DECLARE_REGISTRY_RESOURCEID(IDR_STUDERENDE)
DECLARE_GET_CONTROLLING_UNKNOWN()

DECLARE_PROTECT_FINAL_CONSTRUCT()

BEGIN_COM_MAP(CStuderende)
	COM_INTERFACE_ENTRY(IStuderende)
	COM_INTERFACE_ENTRY(IDispatch)
	COM_INTERFACE_ENTRY(ISupportErrorInfo)
	COM_INTERFACE_ENTRY_AGGREGATE(IID_IMarshal, m_pUnkMarshaler.p)
END_COM_MAP()

	HRESULT FinalConstruct()
	{
		return CoCreateFreeThreadedMarshaler(
			GetControllingUnknown(), &m_pUnkMarshaler.p);
	}

	void FinalRelease()
	{
		m_pUnkMarshaler.Release();
	}

	CComPtr<IUnknown> m_pUnkMarshaler;

// ISupportsErrorInfo
	STDMETHOD(InterfaceSupportsErrorInfo)(REFIID riid);

// IStuderende
public:
	STDMETHOD(FjernKarakter)(/*[in]*/ IKarakter * pKarakter);
	STDMETHOD(TildelKarakter)(/*[in]*/ IFag * pFag, /*[in]*/ IKarakter * pKarakter);
	STDMETHOD(get_Init)(/*[out, retval]*/ BSTR *pVal);
	STDMETHOD(put_Init)(/*[in]*/ BSTR newVal);
	STDMETHOD(get_DatoNotater)(/*[out, retval]*/ IEnumDatoNotat * *pVal);
	STDMETHOD(get_Adresser)(/*[out,retval]*/ IEnumAdresse ** ppEnumAdresse);
	STDMETHOD(OpretDatoNotat)(/*[out,retval]*/ IDatoNotat ** ppDatoNotat);
	STDMETHOD(put_Adresse)(/*[in]*/ IAdresse * newVal);
	STDMETHOD(get_GUID)(/*[out, retval]*/ BSTR *pVal);
	STDMETHOD(put_GUID)(/*[in]*/ BSTR newVal);
	STDMETHOD(OpretAdresse)(/*[out,retval]*/ IAdresse ** pVal);
	STDMETHOD(get_BrugerNavn)(/*[out, retval]*/ BSTR *pVal);
	STDMETHOD(put_BrugerNavn)(/*[in]*/ BSTR newVal);
	STDMETHOD(get_Identifikation)(/*[out, retval]*/ BSTR *pVal);
	STDMETHOD(put_Identifikation)(/*[in]*/ BSTR newVal);
	STDMETHOD(get_Status)(/*[out, retval]*/ BSTR *pVal);
	STDMETHOD(put_Status)(/*[in]*/ BSTR newVal);
	STDMETHOD(get_CPRNr)(/*[out, retval]*/ BSTR *pVal);
	STDMETHOD(put_CPRNr)(/*[in]*/ BSTR newVal);
	STDMETHOD(get_OKDato)(/*[out, retval]*/ BSTR *pVal);
	STDMETHOD(put_OKDato)(/*[in]*/ BSTR newVal);
	STDMETHOD(get_SkoleDato)(/*[out, retval]*/ BSTR *pVal);
	STDMETHOD(put_SkoleDato)(/*[in]*/ BSTR newVal);
	STDMETHOD(get_SkoleId)(/*[out, retval]*/ BSTR *pVal);
	STDMETHOD(put_SkoleId)(/*[in]*/ BSTR newVal);
	STDMETHOD(get_Uddannelse)(/*[out, retval]*/ BSTR *pVal);
	STDMETHOD(put_Uddannelse)(/*[in]*/ BSTR newVal);
	STDMETHOD(get_Bemaerkning)(/*[out, retval]*/ BSTR *pVal);
	STDMETHOD(put_Bemaerkning)(/*[in]*/ BSTR newVal);
	STDMETHOD(GetInfo)();
	STDMETHOD(get_Titel)(/*[out, retval]*/ BSTR *pVal);
	STDMETHOD(put_Titel)(/*[in]*/ BSTR newVal);
	STDMETHOD(get_Efternavn)(/*[out, retval]*/ BSTR *pVal);
	STDMETHOD(put_Efternavn)(/*[in]*/ BSTR newVal);
	STDMETHOD(get_Fornavn)(/*[out, retval]*/ BSTR *pVal);
	STDMETHOD(put_Fornavn)(/*[in]*/ BSTR newVal);
	STDMETHOD(SetInfo)();
private:
	CStuderendeImpl * m_studImpl;
};

#endif //__STUDERENDE_H_
